Fixes for low-color displays and a slight enhancement for true-color
authorCST 1998 Shawn T. Amundson <amundson@gtk.org>
Thu, 3 Dec 1998 05:52:19 +0000 (05:52 +0000)
committerShawn Amundson <amundson@src.gnome.org>
Thu, 3 Dec 1998 05:52:19 +0000 (05:52 +0000)
Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>

        * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
          enhancement for true-color displays.

        * INSTALL:
          README:
          configure.in:
          gtk+.spec:
          docs/gtk-config.1: up to version 1.1.6

13 files changed:
ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
INSTALL
README
configure.in
docs/gtk-config.1
gtk+.spec
gtk/gtkpixmap.c

index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
index 46d87f0e21bdece1eabc3d56f919eef7ccda2b78..66dba6fc56b91cfce2bb17e38653bcfa16770a4b 100644 (file)
@@ -1,3 +1,14 @@
+Wed Dec  2 17:45:21 CST 1998 Shawn T. Amundson <amundson@gtk.org>
+
+       * gtk/gtkpixmap.c: Fixes for low-color displays and a slight
+         enhancement for true-color displays.
+
+       * INSTALL:
+         README:
+         configure.in:
+         gtk+.spec:
+         docs/gtk-config.1: up to version 1.1.6
+
 Wed Dec  2 01:36:49 PST 1998 Manish Singh <yosh@gimp.org>
 
        * gtk/gtkfeatures.h.in: lets #define GTK_HAVE_FEATURES_1_1_6 before
diff --git a/INSTALL b/INSTALL
index 6986321acae1767a3605f548c7369441344791c2..368caf2555aaea9072e9ae01f3541556b9010f95 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -7,8 +7,8 @@ you got this package.
 Simple install procedure
 ========================
 
-  % gzip -cd gtk+-1.1.5.tar.gz | tar xvf - # unpack the sources
-  % cd gtk+-1.1.5                          # change to the toplevel directory
+  % gzip -cd gtk+-1.1.6.tar.gz | tar xvf - # unpack the sources
+  % cd gtk+-1.1.6                          # change to the toplevel directory
   % ./configure                            # run the `configure' script
   % make                                   # build GTK
   [ Become root if necessary ]
@@ -92,7 +92,7 @@ You can compile GTK+ against a copy of GLIB that you have not
 yet installed. To do this, give the --with-glib=DIR options
 to ./configure. For instance:
 
- ./configure --with-glib=../glib-1.1.5
+ ./configure --with-glib=../glib-1.1.6
 
 This, however, will not work if you built GLIB with different
 source and build directories.
diff --git a/README b/README
index 75370f9ff19443906a37fa84b11020691d575a4d..4f1bcc563696b4cbca5b54740faff646ec408061 100644 (file)
--- a/README
+++ b/README
@@ -1,7 +1,7 @@
 General Information
 ===================
 
-This is GTK+ version 1.1.5.   GTK+, which stands for the Gimp ToolKit, 
+This is GTK+ version 1.1.6.   GTK+, which stands for the Gimp ToolKit, 
 is a library for creating graphical user interfaces for the X Window 
 System. It is designed to be small, efficient, and flexible. GTK+ is 
 written in C with a very object-oriented approach.
index a2870a575f9d2d2167f0832846c8a58637eced06..1c8f0494c021b1e7145e582a4e1362eeee770b37 100644 (file)
@@ -177,7 +177,7 @@ if test x$with_glib = x ; then
 
   AM_PATH_GLIB(1.1.6,,
     AC_MSG_ERROR([
-*** GLIB 1.1.5 or better is required. The latest version of GLIB
+*** GLIB 1.1.6 or better is required. The latest version of GLIB
 *** is always available from ftp://ftp.gtk.org.]),
     gmodule)
 
index 054ee2e9bb2198a3033ebe87ff7e89cf10202724..df251aeab471e4777f9b2281a5aace47fb3ab04a 100644 (file)
@@ -1,4 +1,4 @@
-.TH GTK+ 1 "25 October 1998" Version 1.1.5
+.TH GTK+ 1 "25 October 1998" Version 1.1.6
 .SH NAME
 gtk-config - script to get information about the installed version of GTK+
 .SH SYNOPSIS
index 9c2a9f0a62969d2ef54d06da6baa7779fd72956b..21c2770583f18935916bf464aa0cccf20bcc71e5 100644 (file)
--- a/gtk+.spec
+++ b/gtk+.spec
@@ -1,5 +1,5 @@
 # Note that this is NOT a relocatable package
-%define ver      1.1.5
+%define ver      1.1.6
 %define rel      SNAP
 %define prefix   /usr
 
index f1e66253583899e7cef6a66188e75c2a5aaa6f62..2b00d04d1168c72131c26399a9f25aec3f5a26b7 100644 (file)
@@ -263,63 +263,85 @@ build_insensitive_pixmap(GtkPixmap *gtkpixmap)
   gint32 red, green, blue;
   GtkStyle *style;
   GtkWidget *window;
+  GdkColor c;
+  int failed;
 
   window = GTK_WIDGET (gtkpixmap);
 
   g_return_if_fail(window != NULL);
 
   gdk_window_get_size(pixmap, &w, &h);
-  visual = gtk_widget_get_visual(GTK_WIDGET(gtkpixmap));
-  cmap = gtk_widget_get_colormap(GTK_WIDGET(gtkpixmap));
+  image = gdk_image_get(pixmap, 0, 0, w, h);
+  insensitive = gdk_pixmap_new(GTK_WIDGET (gtkpixmap)->window, w, h, -1);
   gc = gdk_gc_new (pixmap);
 
+  visual = gtk_widget_get_visual(GTK_WIDGET(gtkpixmap));
+  cmap = gtk_widget_get_colormap(GTK_WIDGET(gtkpixmap));
   cc = gdk_color_context_new(visual, cmap);
+
   if ((cc->mode != GDK_CC_MODE_TRUE) && (cc->mode != GDK_CC_MODE_MY_GRAY)) 
     {
-      gdk_color_context_free(cc);
+      gdk_draw_image(insensitive, gc, image, 0, 0, 0, 0, w, h);
+
       style = gtk_widget_get_style(window);
       color = style->bg[0];
       gdk_gc_set_foreground (gc, &color);
-      for (y = 0; y < h; y ++) 
+      for (y = 0; y < h; y++) 
         {
           for (x = y % 2; x < w; x += 2) 
            {
-              gdk_draw_point(pixmap, gc, x, y);
+              gdk_draw_point(insensitive, gc, x, y);
             }
         }
-                gdk_gc_destroy(gc);
-                return;
-     }
-
-   image = gdk_image_get(pixmap, 0, 0, w, h);
-   gdk_gc_get_values(gc, &vals);
-   style = gtk_widget_get_style(window);
-   color = style->bg[0];
-   red = color.red;
-   green = color.green;
-   blue = color.blue;
-   for (y = 0; y < h; y++) 
-     {
-       for (x = 0; x < w; x++) 
-         {
-           GdkColor c;
-           int failed;
-           c.pixel = gdk_image_get_pixel(image, x, y);
-           gdk_color_context_query_color(cc, &c);
-           c.red = (((gint32)c.red - red) >> 1) + red;
-           c.green = (((gint32)c.green - green) >> 1) + green;
-           c.blue = (((gint32)c.blue - blue) >> 1) + blue;
-           c.pixel = gdk_color_context_get_pixel(cc, c.red, c.green, c.blue,
-                                                 &failed);
-           gdk_image_put_pixel(image, x, y, c.pixel);
-         }
-     }
-     insensitive = gdk_pixmap_new(GTK_WIDGET (gtkpixmap)->window, w, h, -1);
-     gdk_draw_image(insensitive, gc, image, 0, 0, 0, 0, w, h);
-     gtkpixmap->pixmap_insensitive = insensitive;
-     gdk_image_destroy(image);
-     gdk_gc_destroy(gc);
-     gdk_color_context_free(cc);
+    }
+  else
+    {
+      gdk_gc_get_values(gc, &vals);
+      style = gtk_widget_get_style(window);
+
+      color = style->bg[0];
+      red = color.red;
+      green = color.green;
+      blue = color.blue;
+
+      for (y = 0; y < h; y++) 
+       {
+         for (x = 0; x < w; x++) 
+           {
+             c.pixel = gdk_image_get_pixel(image, x, y);
+             gdk_color_context_query_color(cc, &c);
+             c.red = (((gint32)c.red - red) >> 1) + red;
+             c.green = (((gint32)c.green - green) >> 1) + green;
+             c.blue = (((gint32)c.blue - blue) >> 1) + blue;
+             c.pixel = gdk_color_context_get_pixel(cc, c.red, c.green, c.blue,
+                                                   &failed);
+             gdk_image_put_pixel(image, x, y, c.pixel);
+           }
+       }
+
+      for (y = 0; y < h; y++) 
+       {
+         for (x = y % 2; x < w; x += 2) 
+           {
+             c.pixel = gdk_image_get_pixel(image, x, y);
+             gdk_color_context_query_color(cc, &c);
+             c.red = (((gint32)c.red - red) >> 1) + red;
+             c.green = (((gint32)c.green - green) >> 1) + green;
+             c.blue = (((gint32)c.blue - blue) >> 1) + blue;
+             c.pixel = gdk_color_context_get_pixel(cc, c.red, c.green, c.blue,
+                                                   &failed);
+             gdk_image_put_pixel(image, x, y, c.pixel);
+           }
+       }
+
+      gdk_draw_image(insensitive, gc, image, 0, 0, 0, 0, w, h);
+    }
+
+  gtkpixmap->pixmap_insensitive = insensitive;
+
+  gdk_image_destroy(image);
+  gdk_color_context_free(cc);
+  gdk_gc_destroy(gc);
 }